import { createApp, h } from "vue";
import App from "./App.vue";
import "./index.css";
import Test1Plugin from "./page3/plugins/test1";
// import * as Vlf from 'vlf'
// import * as localforage from 'localforage'

let vm = createApp(App);
vm.use(Test1Plugin, { good: "123" });
// vm.use(Vlf, localforage)
vm.component("anchored-heading", {
  render() {
    return h(
      "h" + this.level, // tag name
      {}, // props/attributes
      this.$slots.default() // array of children
    );
  },
  props: {
    level: {
      type: Number,
      required: true,
    },
  },
});

vm.component("anchored", {
  render() {
    return (
      <div>
        <anchored-heading level={1}> h11 </anchored-heading>
        <anchored-heading level={2}> h2 </anchored-heading>
      </div>
    );
  },
});
vm.mount("#app");
